const child_process = require('child_process');
const {resolve} = require('path');
const script = resolve(__dirname, '../crawler/movie.js');

(async () => {

	let child = child_process.fork(script);

	child.on('message', (data) => {
		console.log(data)
	});

	child.on('exit', (code) => {
		console.log(code)
	});

})();